var xmlHttp;
function createXMLHttpRequest(){
    if(window.XMLHttpRequest){ 
        xmlHttp = new XMLHttpRequest();
    }else if(window.ActiveXObject) {
    	try{
        	xmlHttp = new ActiveXObject("Msxml2.XMLHTTP");
        }catch(e){
        	try {
            	xmlHttp = new ActiveXObject("Microsoft.XMLHTTP");
        	}catch(e){}
        }
    }
    if(xmlHttp==null){
    	alert("不能创建XMLHttpRequest对象");
    	return false;
    }
}
function sendAsynchronRequest(url,parameter,callback){
	createXMLHttpRequest();
	if(parameter == null){
		xmlHttp.onreadystatechange = callback;
		xmlHttp.open("GET",url,true);
		xmlHttp.send(null);
	}else{
		xmlHttp.onreadystatechange = callback;
		xmlHttp.open("POST",url,true);
		xmlHttp.setRequestHeader("Content-Type","application/x-www-form-urlencoded;");
		xmlHttp.send(parameter);
	}
}